import { getPage, get, post } from '../../request'

const ns = '/flw/flow-run'

export const flowRunApi = {
  /**
   * 查询待办分页
   * @param params
   * @returns
   */
  findTodoPage: (page: AxiosType.Pagination, params?: { [key: string]: any }) => {
    return getPage({ url: `${ns}/todo/page`, params }, page)
  },

  /**
   * 查询流程历史记录列表
   * @param pInstanceId
   * @returns
   */
  findTask: (pInstanceId: string) => {
    return get({ url: `${ns}/task/his/${pInstanceId}` })
  }
}
